package com.ooolong.expression;

public class ONumber extends OObject {

	public ONumber(Object obj) {
		super();
		this.obj = obj;

		if (obj instanceof Byte) {
			this.type = BYTE;
			this.name = "byte";
		} else if (obj instanceof Short) {
			this.type = SHORT;
			this.name = "short";
		} else if (obj instanceof Integer) {
			this.type = INTEGER;
			this.name = "integer";
		} else if (obj instanceof Long) {
			this.type = LONG;
			this.name = "long";
		} else if (obj instanceof Float) {
			this.type = FLOAT;
			this.name = "float";
		} else if (obj instanceof Double) {
			this.type = DOUBLE;
			this.name = "double";
		}
	}

	@Override
	public OObject execute(OObject[] args) throws ExpressionException {
		return this;
	}
}
